<?php
/**
 * 用户类
 */
abstract class User{
	function __construct($name);
	
	function login($name,$psw);
	
	function logout($uid);
	
	function register($name,$psw);
	
	function readPermission();
	
	function writePermission();
	
	function deletePermission();
	
	/*扩充权限*/
	function modifyPermission();
	
	/*扩展接口*/
	function extendInterface();
	
	protected $name = NULL;
	protected $psw = NULL;
}
/*管理员用户*/
class AdminUser extends User{
	function writePermission(){
		return true;
	}
	function deletePermission(){
		return true;
	}
	function modifyPermission(){
		return true;
	}
	function extendInterface($module){
		return true;
	}
}
/*默认用户*/
class GuestUser extends User{
	
}
/*用户组*/
class UserGroup extends User {
	//Login-> Module -> Permission
}

?>